home *** CD-ROM | disk | FTP | other *** search
/ CyberMycha Extra 2004 January / CyberMycha Extra 1-2004 (Poland) (Disc 2).bin / Pippi / gmdl.dir / Internal_41_dlScript.ls < prev    next >
Encoding:
Text File  |  2001-09-04  |  1.8 KB  |  94 lines

  1. property tommy, annika, pippi, water, stopL, stopR, pippiV, originFrame
  2.  
  3. on new me
  4.   repeat with n = 1 to 38
  5.     member(n, 1).scale = 100
  6.   end repeat
  7.   stopL = 133
  8.   stopR = 667
  9.   pippiV = 391
  10.   return me
  11. end
  12.  
  13. on recoverTA me
  14.   tommy.recoverX()
  15.   annika.recoverX()
  16. end
  17.  
  18. on mouseHX me
  19.   if pippi.playing = 0 then
  20.     if (pippi.locH > stopL) and (pippi.locH < stopR) then
  21.       if pippi.locH < (the mouseH - 50) then
  22.         if pippi.locH < (stopR - pippi.moveAmount) then
  23.           v = 1
  24.         else
  25.           v = 0
  26.         end if
  27.       else
  28.         if pippi.locH > (the mouseH + 50) then
  29.           if pippi.locH > (stopL + pippi.moveAmount) then
  30.             v = -1
  31.           else
  32.             v = 0
  33.           end if
  34.         else
  35.           v = 0
  36.         end if
  37.       end if
  38.       if pippi.member <> member(string(v), 1) then
  39.         pippi.member = member(string(v), 1)
  40.       end if
  41.     end if
  42.   end if
  43. end
  44.  
  45. on keyHXright me
  46.   if pippi.playing = 0 then
  47.     if pippi.locH < (stopR - pippi.moveAmount) then
  48.       v = 1
  49.     else
  50.       v = 0
  51.     end if
  52.     if pippi.member <> member(string(v), 1) then
  53.       pippi.member = member(string(v), 1)
  54.       pippi.play()
  55.     end if
  56.   end if
  57. end
  58.  
  59. on keyHXleft me
  60.   if pippi.playing = 0 then
  61.     if pippi.locH > (stopL + pippi.moveAmount) then
  62.       v = -1
  63.     else
  64.       v = 0
  65.     end if
  66.     if pippi.member <> member(string(v), 1) then
  67.       pippi.member = member(string(v), 1)
  68.       pippi.play()
  69.     end if
  70.   end if
  71. end
  72.  
  73. on keyHitDown me
  74.   if the frameLabel = "main" then
  75.     case the keyCode of
  76.       49:
  77.         pippi.keyDownX()
  78.       123:
  79.         me.keyHXleft()
  80.       124:
  81.         me.keyHXright()
  82.     end case
  83.   end if
  84. end
  85.  
  86. on keyHitUp me
  87.   if the frameLabel = "main" then
  88.     case the keyCode of
  89.       49:
  90.         pippi.keyUpX()
  91.     end case
  92.   end if
  93. end
  94.